package com.example.pdftoofd.entity;

import java.util.Date;

public class HistoryEntity {
    private String FileName;
    private Date date;
    private String Status;

    public String getFileName() {
        return FileName;
    }

    public void setFileName(String fileName) {
        FileName = fileName;
    }

    public Date getDate() {
        return date;
    }

    public void setDate(Date date) {
        this.date = date;
    }

    public String getStatus() {
        return Status;
    }

    public void setStatus(String status) {
        Status = status;
    }

    public static HistoryEntity success(String fileName, Date date) {
        return getInstance(fileName, date, "成功");
    }

    public static HistoryEntity fail(String fileName, Date date, String status) {
        return getInstance(fileName, date, status);
    }

    public static HistoryEntity getInstance(String fileName, Date date, String status) {
        HistoryEntity historyEntity = new HistoryEntity();
        historyEntity.setFileName(fileName);
        historyEntity.setDate(date);
        historyEntity.setStatus(status);
        return historyEntity;
    }
}
